
<%@page import="java.io.File"%>
<%@page import="example_of_use.PlotTesting"%>
<%@page import="main.LogicImageSegmentation"%>

<%@page import="javax.swing.JFrame"%>
<%
    // call new JFrame
    // show data distribution graph

    int attr_id = Integer.parseInt(request.getParameter("id"));    

    if (attr_id < 0 && attr_id > 19) {
        
        
        out.println("false");
    } else {
        String appPath = config.getServletContext().getRealPath("/");

        // data set path                 
        File ff = new File(appPath);
        String dataSetPath = ff.toString() + "/";     // get /ImageSegmentation/ ..
        File fff = new File(dataSetPath);

        
        // call the new jframe
        // only can do it in server
        // 	 		
	out.println("true");
        //System.out.println("LOGG "+LogicImageSegmentation.FILE_DATA_SET_NAME_ARFF);
        
        //out.println(LogicImageSegmentation.FILE_DATA_SET_NAME_ARFF );
        //out.println("true");
        try{
	PlotTesting pt = new PlotTesting(dataSetPath+LogicImageSegmentation.FILE_DATA_SET_NAME_ARFF, attr_id);
        
               }catch(Exception e){
                   out.println("damn");
               }
  //      out.println("true");
        //out.println("<script type='text/javascript'>");
        //out.println("parent.document.getElementById('status').innerHTML=\""+LogicImageSegmentation.FILE_DATA_SET_NAME_ARFF+"\"; ");
        //out.println("</script>");

   }

%>   